//
// Created by Administrator on 2022/1/17.
//

#ifndef RAPIDSVN_WIN_MYAPP_H
#define RAPIDSVN_WIN_MYAPP_H


#pragma once

#define  wxUSE_GUI 0

#include <wx/app.h>
#include <wx/cmdline.h>
#include <wx/snglinst.h>
#include <wx/dynlib.h>
#include <wx/process.h>

wxDECLARE_EVENT(wxMY_EVT_1, wxThreadEvent);

class MyApp :public wxAppConsole
{
public:
    virtual bool OnInit() override;
    virtual int OnExit() override;
    virtual int FilterEvent(wxEvent& event) override;
    virtual void OnInitCmdLine(wxCmdLineParser& parser) override;

    virtual bool OnCmdLineParsed(wxCmdLineParser& parser) override;

    virtual bool OnCmdLineHelp(wxCmdLineParser& parser) override;

    virtual bool OnCmdLineError(wxCmdLineParser& parser) override;
protected:
    wxSingleInstanceChecker * m_checker;
    wxProcess * m_process;
    wxDynamicLibrary m_dynlib;
};

wxDECLARE_APP(MyApp);


#endif //RAPIDSVN_WIN_MYAPP_H
